<?php
	//
	session_start();
	//
	require_once("config.php");
	require_once("function.php");
	//
	if($_SESSION["login"] != "logged")
	{
		Header("Location:$URL");
	}
	
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Editor on BossEditor</title>
<link href="main.css" rel="stylesheet" type="text/css" media="screen" />
<!--<script language="javascript" type="text/javascript" src="codepress/codepress.js"></script>-->

<script language="javascript" type="text/javascript" src="edit_area/edit_area_full.js"></script>
<script language="javascript" type="text/javascript">
editAreaLoader.init({
	id: "myCpWindow",	// textarea id
	syntax:'php',
	toolbar: "search, go_to_line, |, undo, redo, |, select_font, |, syntax_selection, |, change_smooth_selection, highlight, reset_highlight, |, help",
	start_highlight: true,		// to display with highlight mode on start-up
	syntax_selection_allow: "css,html,js,php,python,vb,xml,c,cpp,sql,basic,pas,brainfuck,text",
	replace_tab_by_spaces: 4,
	allow_resize: "no",
	allow_toggle: false,
	is_multi_files: true
});
</script>


<script language="javascript" type="text/javascript" src="jquery.js"></script>
<script language="javascript" text="text/javascript" src='edit.js'></script>
</head>
<body>

<div id="main_div">


	<div id="menu_div">
		<span id="saveButton" class="float_left button">Save</span>
		<span id="msgbox" class="float_left"></span>
		<span class="float_right button" onclick="window.location.href='login.php?action=logout'">Logout</span>
	</div>


	<div id="editor">
		<textarea id="myCpWindow" class="myCpWindow"></textarea>
	</div>
	
	<div id="sidebar">	
		<div id="file_list">
			<!-- This DIV will be instead by file list -->
		</div>

		<div id="cr_input">
			<span id="newFileBtn" class="button">Create New Files</span>
		</div>
	</div>
	

	<div id="toolBar">
		<p id="fileName"></p>
	</div>

</div>

</body>
</html>
